function [ globalMaxIdx, globalMaxXVal ] = findMaxVel( xVals, yVals )
% Finds maximum of velocity peaks

[maximaYVals, maximaIndeces] = findpeaks(yVals);

globalMaxIdx = maximaIndeces(1);
globalMaxXVal = xVals(globalMaxIdx);


end

